Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

233
Visualizações
Undefined is not an Object: "Unable to Resolve Path" in React Native JavaScript

I am trying to use path aliases in react-native without typescript. I have followed some articles to implement it using babel-plugin-module-resolver. Everything was working till yesterday and now suddenly it's showing this error. I have developed the complete frontend now was integrating APIs and suddenly this error came.

This is an attached image of the error Idk why it's coming

I tried following several guides from the internet none of them worked for me. What should I do?

{
  "presets": ["react-native"],
  "plugins": [
    ["module-resolver", {
      "cwd": "babelrc",
      "root": "./app",
      "alias": {
        "src/*": "./src/*",
        "@components": "./src/components/index",
        "@app/*": "./src/app/*",
        "cdn/": "./src/cdn/"
      }
    }]
  ]
}

This is my latest .babelrc file.

about 4 years ago · Juan Pablo Isaza
2 Respostas
Responde à pergunta

0

Sometimes the solution for this kind of alias problems is to just close and restart your IDE, this happens to me when changing some stuff in tsconfig so maybe it could work in your case too.

If I recall correctly there is a command in VS Code that does that without having to close your project (Reload JavaScript Project).

about 4 years ago · Juan Pablo Isaza Relatório

0

Add the following to your eslintrc file to resolve the path issue:

{
  "settings": {
    "import/resolver": {
      "node": {
        "extensions": [".js", ".jsx", ".ts", ".tsx"]
      }
    }
  },
about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda